<!DOCTYPE html>
<html class="x-admin-sm">

<head>
	<meta charset="UTF-8" />
	<title>优点达资讯管理系统</title>
	<meta name="renderer" content="webkit|ie-comp|ie-stand" />
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
	<meta name="viewport"
		content="width=device-width,user-scalable=yes, minimum-scale=0.4, initial-scale=0.8,target-densitydpi=low-dpi" />
	<meta http-equiv="Cache-Control" content="no-siteapp" />
	<script>
		localStorage.getItem('ydd-token') ? '' : location.href = './login.html'
	</script>
	<link rel="stylesheet" href="./css/font.css">
	<link rel="stylesheet" href="./css/font-awesome.css" />
	<link rel="stylesheet" href="./css/xadmin.css" />
	<link rel="stylesheet" href="./css/theme6.css" />
	<link href="//unpkg.com/layui@2.8.3/dist/css/layui.css" rel="stylesheet">
	<style>
		.class-demo-layer-lockscreen {
  background-image: url("./石昊.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
	position: relative;
  /* 其他样式规则 */
}
#ID-layer-demo-inst .layui-form{ 
position: absolute;
top: 300px;
left: 600px;
}
.class-demo-layer-pin{
	width: 200px;
	height: 30px;
}
.lock{
	text-align: center;
}
	</style>
	<script src="./lib/layui/layui.js" charset="utf-8"></script>
	<!-- <script src="./js/common.js"></script> -->
	<script type="text/javascript" src="./js/xadmin.js"></script>
	<!-- 让IE8/9支持媒体查询，从而兼容栅格 -->
	<!--[if lt IE 9]>
			<script src="https://cdn.staticfile.org/html5shiv/r29/html5.min.js"></script>
			<script src="https://cdn.staticfile.org/respond.js/1.4.2/respond.min.js"></script>
		<![endif]-->
	<script>
			// 是否开启刷新记忆tab功能
			// var is_remember = false;
	</script>
</head>

<body class="index">
	<!-- 顶部开始 -->
	<div class="container">
		<div class="logo">
			<a href="./index.html">优点达管理系统</a>
		</div>
		<div class="left_open">
			<a><i title="展开左侧栏" class="fa fa-bars"></i></a>
		</div>
		<ul class="layui-nav right" lay-filter="">
			<li class="layui-nav-item">
				<a href="javascript:;">admin</a>
				<dl class="layui-nav-child">
					<!-- 二级菜单 -->

					<dd>
					  <button type="button" class="layui-btn layui-btn-primary" lay-on="test-more-lockscreen">
							页面锁屏 <span class="layui-badge-dot"></span>
						</button>
					</dd>
					<dd>
						<a href="./login.html">退出</a>
					</dd>
				</dl>
			</li>

		</ul>
	</div>
	<!-- 顶部结束 -->
	<!-- 中部开始 -->
	<!-- 左侧菜单开始 -->
	<div class="left-nav">
		<div id="side-nav">
			<ul id="nav">
				<li>
					<a onclick="xadmin.add_tab('后台首页','welcome.html')">
						<i class="fa fa-tachometer left-nav-li" lay-tips="后台首页"></i>
						<cite>后台首页</cite>
					</a>
				</li>
				<li>
					<a onclick="xadmin.add_tab('分类管理','cate.html')">
						<i class="fa fa-list left-nav-li" lay-tips="分类管理"></i>
						<cite>分类管理</cite>
					</a>
				</li>
				<li>
					<a onclick="xadmin.add_tab('标签管理','tags.html')">
						<i class="fa fa-tags left-nav-li" lay-tips="标签管理"></i>
						<cite>标签管理</cite>
					</a>
				</li>
				<li>
					<a onclick="xadmin.add_tab('文章管理','article.html')">
						<i class="fa fa-file-text left-nav-li" lay-tips="文章管理"></i>
						<cite>文章管理</cite>
					</a>
				</li>
				<li>
					<a href="javascript:;">
						<i class="fa fa-object-ungroup left-nav-li" lay-tips="广告管理"></i>
						<cite>广告管理</cite>
						<i class="fa fa-angle-right  nav_right"></i>
					</a>
					<ul class="sub-menu">
						<li>
							<a onclick="xadmin.add_tab('广告位管理','advpos.html')">
								<i class="fa fa-linode left-nav-li" lay-tips="友情链接管理"></i>
								<cite>广告位管理</cite></a>
						</li>
						<li>
							<a onclick="xadmin.add_tab('广告图管理','advimg.html')">
								<i class="fa fa-picture-o left-nav-li" lay-tips="友情链接管理"></i>
								<cite>广告图管理</cite></a>
						</li>
						<li>
							<a onclick="xadmin.add_tab('友情链接管理','link.html')">
								<i class="fa fa-link left-nav-li" lay-tips="友情链接管理"></i>
								<cite>友情链接管理</cite>
							</a>
						</li>
					</ul>
				</li>
				<li>
					<a onclick="xadmin.add_tab('系统设置','setting.html')">
						<i class="fa fa-gear left-nav-li" lay-tips="系统设置"></i>
						<cite>系统设置</cite>
					</a>
				</li>
			</ul>
		</div>
	</div>
	<!-- <div class="x-slide_left"></div> -->
	<!-- 左侧菜单结束 -->
	<!-- 右侧主体开始 -->
	<div class="page-content">
		<div class="layui-tab tab" lay-filter="xbs_tab" lay-allowclose="false">
			<ul class="layui-tab-title">
				<li class="home">
					<i class="layui-icon">&#xe68e;</i>我的桌面
				</li>
			</ul>
			<div class="layui-unselect layui-form-select layui-form-selected" id="tab_right">
				<dl>
					<dd data-type="this">关闭当前</dd>
					<dd data-type="other">关闭其它</dd>
					<dd data-type="all">关闭全部</dd>
				</dl>
			</div>
			<div class="layui-tab-content">
				<div class="layui-tab-item layui-show">
					<iframe src="./advimg.html" frameborder="0" scrolling="yes" class="x-iframe"></iframe>
				</div>
			</div>
			<div id="tab_show"></div>
		</div>
	</div>
	<div class="page-content-bg"></div>
	<style id="theme_style"></style>
	<!-- 右侧主体结束 -->
	<!-- 中部结束 -->
	<script src="./js/jquery.min.js"></script>
	<script src="//unpkg.com/layui@2.8.3/dist/layui.js"></script> 
	<script>
		// 退出功能
		let layer = layui.layer

		layui.use(function(){
var util = layui.util;
var form = layui.form;
var $ = layui.$;
// 事件
util.on('lay-on', {
'test-more-lockscreen': function(){
layer.open({
  type: 1,
  title: false, // 禁用标题栏
  closeBtn: false, // 禁用默认关闭按钮
  area: ['100%', '100%'],

  id: 'ID-layer-demo-inst',
  skin: 'class-demo-layer-lockscreen', // className
  content: ['<div class="layui-form">',
    '<div class="layui-input-wrap">',
      '<input type="password" class="class-demo-layer-pin" lay-affix="eye">',
      '<div class="layui-input-suffix">',
        '<i class="layui-icon layui-icon-right" id="ID-layer-demo-unlock"></i>',
      '</div>',
    '</div>',
    '<div class="lock">输入 111111 后回车，即可退出锁屏</div>',
  '</div>'].join(''),
  success: function(layero, index){
    var input = layero.find('input');
    var PASS = '111111';
    
    form.render(); // 表单组件渲染
    input.focus();
    // 点击解锁按钮
    var elemUnlock = layero.find('#ID-layer-demo-unlock');
    elemUnlock.on('click', function(){
      if($.trim(input[0].value) === PASS){
        layer.close(index);
        layer.closeLast('dialog'); // 关闭最新打开的信息框
      } else {
        layer.msg('锁屏密码输入有误', {offset: '16px', anim: 'slideDown'})
        input.focus();
      }
    });
    // 回车
    input.on('keyup', function(e){
      var elem = this;
      var keyCode = e.keyCode;
      if(keyCode === 13){
        elemUnlock.trigger('click');
      }
    });
  }
})
},
})
		})






















		document.querySelector('#btnLogout').addEventListener('click',function(){
			// alert('ok')
			layer.confirm("确认退出登录吗？", { icon: 3, title: '提示' },
				function (index) {
					// 退出：
					// 1. 清除 本地存储的token
					// 2. 跳转到 login.html
					localStorage.removeItem('ydd-token')
					location.href = 'login.html'
					layer.close(index)
				})
		})

		//百度统计可去掉
		// var _hmt = _hmt || []
		// ;(function () {
		// 	var hm = document.createElement('script')
		// 	hm.src =
		// 		'https://hm.baidu.com/hm.js?b393d153aeb26b46e9431fabaf0f6190'
		// 	var s = document.getElementsByTagName('script')[0]
		// 	s.parentNode.insertBefore(hm, s)
		// })()layui.use(function(){
var util = layui.util;
var form = layui.form;
var $ = layui.$;
// 事件
util.on('lay-on', {
'test-more-lockscreen': function(){
layer.open({
  type: 1,
  title: false, // 禁用标题栏
  closeBtn: false, // 禁用默认关闭按钮
  area: ['100%', '100%'],

  id: 'ID-layer-demo-inst',
  skin: 'class-demo-layer-lockscreen', // className
  content: ['<div class="layui-form">',
    '<div class="layui-input-wrap">',
      '<input type="password" class="class-demo-layer-pin" lay-affix="eye">',
      '<div class="layui-input-suffix">',
        '<i class="layui-icon layui-icon-right" id="ID-layer-demo-unlock"></i>',
      '</div>',
    '</div>',
    '<div class="lock">输入 111111 后回车，即可退出锁屏</div>',
  '</div>'].join(''),
  success: function(layero, index){
    var input = layero.find('input');
    var PASS = '111111';
    
    form.render(); // 表单组件渲染
    input.focus();
    // 点击解锁按钮
    var elemUnlock = layero.find('#ID-layer-demo-unlock');
    elemUnlock.on('click', function(){
      if($.trim(input[0].value) === PASS){
        layer.close(index);
        layer.closeLast('dialog'); // 关闭最新打开的信息框
      } else {
        layer.msg('锁屏密码输入有误', {offset: '16px', anim: 'slideDown'})
        input.focus();
      }
    });
    // 回车
    input.on('keyup', function(e){
      var elem = this;
      var keyCode = e.keyCode;
      if(keyCode === 13){
        elemUnlock.trigger('click');
      }
    });
  }
})
},
})



		// 做判断，防止用户通过直接访问index地址而跳过登录操作
		const token = localStorage.getItem('ydd-token')
		if (!token) {
			location.href = 'login.html'
		}



	</script>
	<!-- <script src="./js/ajaxBase.js"></script> -->

	
	<script src="./lib/axios.js"></script>
	<script src="./js/ajaxBase.js"></script>
	<script>
		//百度统计可去掉
		var _hmt = _hmt || []
			; (function () {
				var hm = document.createElement('script')
				hm.src =
					'https://hm.baidu.com/hm.js?b393d153aeb26b46e9431fabaf0f6190'
				var s = document.getElementsByTagName('script')[0]
				s.parentNode.insertBefore(hm, s)
			})()
	</script>
</body>

</html>